﻿<%@ Page Title="" Language="vb" AutoEventWireup="false" MasterPageFile="~/MainAdmin.Master" CodeBehind="AdminUpdateBorrow.aspx.vb" Inherits="QLThuVien.AdminUpdateBorrow" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
<script type="text/javascript" >
    function showPopupQH(s, e) {
       s.GetRowValues(e.visibleIndex, 'taikhoan', function(getTK){
           pc_quahan.SetContentUrl("popup_templates/AdminInfoUserDelay.aspx?taikhoan=" + getTK);
           pc_quahan.Show();
       });
    }
</script> 
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <div class="row">
        <div class="col-md-12">
            <h1 class="page-header">
                Danh Sách Quá Hạn - Cập Nhập Sách Mượn
            </h1>
        </div>
    </div>
    <div class="row">
        <div class="col-md-12">
            <dx:ASPxGridView ID="grid_dsmuon" runat="server" Width="100%" AutoGenerateColumns="False" KeyFieldName="id_sach" ClientIDMode="Static"  >
                <Columns>
                    <dx:GridViewCommandColumn ShowEditButton="True" ShowDeleteButton="True"  VisibleIndex="0" Width="100px" CellStyle-HorizontalAlign="Center">
                        <HeaderStyle Font-Bold="True" BackColor="#428bca" ForeColor="White"  HorizontalAlign="Center"  />

<CellStyle HorizontalAlign="Center"></CellStyle>
                    </dx:GridViewCommandColumn>
                     <dx:GridViewDataColumn FieldName="id_sach" VisibleIndex="1" Caption="Mã Sách" ReadOnly="true" CellStyle-HorizontalAlign="Center">
                         <HeaderStyle Font-Bold="True" BackColor="#428bca" ForeColor="White"  HorizontalAlign="Center"  />
                         <EditFormSettings Visible="False" /> 

<CellStyle HorizontalAlign="Center"></CellStyle>
                    </dx:GridViewDataColumn>
                    <dx:GridViewDataColumn FieldName="taikhoan" VisibleIndex="2" Caption="Tài Khoản" ReadOnly="true" CellStyle-HorizontalAlign="Center">
                            <EditFormSettings Visible="False" /> 
                         <HeaderStyle Font-Bold="True" BackColor="#428bca" ForeColor="White"  HorizontalAlign="Center"  />

<CellStyle HorizontalAlign="Center"></CellStyle>
                    </dx:GridViewDataColumn>
                    <dx:GridViewDataDateColumn FieldName="ngaymuon" VisibleIndex="3" Caption="Ngày Mượn"  CellStyle-HorizontalAlign="Center" >
                                            <EditFormSettings VisibleIndex="0" />
                         <HeaderStyle Font-Bold="True" BackColor="#428bca" ForeColor="White"  HorizontalAlign="Center"  />

<CellStyle HorizontalAlign="Center"></CellStyle>
                    <PropertiesDateEdit DisplayFormatString="dd/MM/yyyy" DisplayFormatInEditMode="True"></PropertiesDateEdit> 
                    </dx:GridViewDataDateColumn> 
                            <dx:GridViewDataDateColumn FieldName="ngaytra" VisibleIndex="3" Caption="Ngày Hẹn Trả"  CellStyle-HorizontalAlign="Center" >
                                            <EditFormSettings VisibleIndex="0" />
                         <HeaderStyle Font-Bold="True" BackColor="#428bca" ForeColor="White"  HorizontalAlign="Center"  />

<CellStyle HorizontalAlign="Center"></CellStyle>
                    <PropertiesDateEdit DisplayFormatString="dd/MM/yyyy" DisplayFormatInEditMode="True"></PropertiesDateEdit>
                     
                    </dx:GridViewDataDateColumn> 
                    <dx:GridViewDataCheckColumn FieldName="kieumuon" VisibleIndex="5" Caption="Kiểu Mượn" CellStyle-HorizontalAlign="Center">
                         <EditFormSettings VisibleIndex="2" />
                         <PropertiesCheckEdit DisplayTextChecked="Mượn Về Nhà" DisplayTextUnchecked="Mượn Tại Chỗ"></PropertiesCheckEdit> 
                         <HeaderStyle Font-Bold="True" BackColor="#428bca" ForeColor="White"  HorizontalAlign="Center"  />
                         <EditItemTemplate>
                             <dx:ASPxComboBox ID="cb_kieumuon" runat="server" ValueType="System.String" 
                                 oninit="cb_kieumuon_Init">
                             <Items>
                                <dx:ListEditItem Text="Mượn Về Nhà" Value="1" />
                                <dx:ListEditItem Text="Mượn Tại Chỗ" Value="0"/> 
                             </Items> 
                             </dx:ASPxComboBox>  
                         </EditItemTemplate> 

<CellStyle HorizontalAlign="Center"></CellStyle>
                    </dx:GridViewDataCheckColumn>
                    <dx:GridViewDataColumn FieldName="tennv" VisibleIndex="6" Caption="Nhân Viên Cho Mượn" ReadOnly="true" CellStyle-HorizontalAlign="Center">
                        <EditFormSettings Visible="False" /> 
                         <HeaderStyle Font-Bold="True" BackColor="#428bca" ForeColor="White"  HorizontalAlign="Center"  />

<CellStyle HorizontalAlign="Center"></CellStyle>
                    </dx:GridViewDataColumn>
                </Columns>
                <Settings ShowFilterRow="True" ShowGroupPanel="True" ShowStatusBar="Hidden" ShowFilterRowMenu="true" ShowGroupButtons="true" ShowFilterRowMenuLikeItem="true" ShowFilterBar="Visible"  ShowFooter="true"    />
                <SettingsEditing EditFormColumnCount="3" />
                <SettingsSearchPanel Visible="True" />   
                <SettingsPager Position="TopAndBottom" PageSizeItemSettings-Items="5,10,15,20" PageSizeItemSettings-Visible="true">
                    <PageSizeItemSettings Items="5, 10, 15, 20" Visible="True">
                    </PageSizeItemSettings>
                </SettingsPager>
                <SettingsBehavior ConfirmDelete="true" />
                <SettingsText ConfirmDelete="Bạn Có Muốn Xóa Không?" />  
                <TotalSummary>
                    <dx:ASPxSummaryItem FieldName= "ngaytra" SummaryType="Custom" />    
                </TotalSummary>
                <ClientSideEvents RowDblClick="showPopupQH"  />
                 <SettingsCommandButton>
            <EditButton Image-IconID="actions_edit_16x16devav" ButtonType="Image">
<Image IconID="actions_edit_16x16devav"></Image>
                     </EditButton>
            <DeleteButton Image-IconID="actions_cancel_16x16office2013" ButtonType="Image">
<Image IconID="actions_cancel_16x16office2013"></Image>
                     </DeleteButton>
            <UpdateButton Image-IconID="actions_refresh_16x16office2013" ButtonType="Image">
<Image IconID="actions_refresh_16x16office2013"></Image>

                     </UpdateButton>
            <CancelButton Image-IconID ="actions_close_16x16devav" ButtonType="Image" >
<Image IconID="actions_close_16x16devav"></Image>
                     </CancelButton>
        </SettingsCommandButton>     
            </dx:ASPxGridView>

        </div>        
    </div>
    <div>
        <dx:ASPxPopupControl ID="pc_quahan" runat="server" Modal="true" PopupVerticalAlign="WindowCenter" PopupHorizontalAlign="WindowCenter" ClientInstanceName="pc_quahan" CloseAnimationType="Fade" HeaderText="Thông Tin Độc Giả"
        Width="700px" Height="250px"> 
        <ClientSideEvents CloseUp="function(s,e){
            s.RefreshContentUrl();
        }" />         
        </dx:ASPxPopupControl>   
    </div>
</asp:Content>
